package com.crm.commons.exception;

import com.crm.commons.exception.enumVo.ExceptionEnum;

/**
 * @author junxian.dou
 * @Package：com.crm.commons.exception
 * @Project：springboot-crm
 * @name：BusinessException
 * @Date：2024/12/4 11:13
 * @Filename：BusinessException
 * @verson 1.0.0
 * @desc
 */
public class BusinessException extends RuntimeException{

    private Integer code;

    private String errorMessage;

    public BusinessException(ExceptionEnum exceptionEnum) {
        this.code = exceptionEnum.getCode();
        this.errorMessage = exceptionEnum.getMessage();
    }
}
